package com.hr.huangzhk.controller;

import com.hr.huangzhk.domain.User;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestMethod;

import javax.servlet.http.HttpSession;

/**
 * Created by showtimehzk on 2016/10/24.
 */
@Controller
@RequestMapping(value = "/myWebSocket")
public class WebSocketController {

  @RequestMapping(value = "/login", method = RequestMethod.GET)
  public String login(HttpSession session) {
    User user = new User();
    user.setId("123");
    session.setAttribute("user", user);
    return "index";
  }


}
